import request from '@/utils/request'

/**
 * 获取统计总数
 */
export function getShopCountList() {
    return request.get(`shop/stat/total`)
}

/**
 * 获取今日统计总数
 */
export function getShopTodayCountList() {
    return request.get(`shop/stat/today`)
}

/**
 * 获取昨日统计总数
 */
export function getShopYesterdayCountList() {
    return request.get(`shop/stat/yesterday`)
}

/**
 * 获取统计图数据
 */
export function getShopStat() {
    return request.get(`shop/stat`)
}

/**
 * 获取订单统计
 */
export function getShopOrderStat() {
    return request.get(`shop/stat/order`)
}

/**
 * 获取商品统计
 */
export function getShopGoodsStat() {
    return request.get(`shop/stat/goods`)
}

/*
 * 获取团队各等级人数统计
 */
export function getShopFenxiaoNumStat() {
    return request.get(`shop/stat/fenxiao`)
}

/**
 * 获取新注册用户统计
 */
export function getShopNewUserStat(params?: Record<string, any>) {
    return request.get(`shop/stat/newuser`, { params })
}

/**
 * 获取消费用户统计
 */
export function getShopConsumptionUserStat(params?: Record<string, any>) {
    return request.get(`shop/stat/consumeuser`, { params })
}

/**
 * 获取复购人员统计
 */
export function getShopRepurchaseUserStat() {
    return request.get(`shop/stat/byconsumeuser`)
}

/**
 * 获取未推广人员统计
 */
export function getShopUnUserStat(params?: Record<string, any>) {
    return request.get(`shop/stat/notfenxianguser`, { params })
}
